<template>
	<view class="home">
		<!-- 弹出层 -->
		<popup :show="getPaperPopup" @close="closePaperPopup"></popup>
	
		<!-- 轮播图 -->
		<view>
			       <u-swiper
			                :list="swiperList"
			                previousMargin="30"
			                nextMargin="30"
			                circular
							indicator
							autoplay
							height="200"
			                radius="5"
			                bgColor="#ffffff"
			        ></u-swiper>
		</view>		
		
		<!-- 存取纸条 -->
		<view class="paper" >
			<view class="paper-save" @click="savePaper">
				存纸条
			</view>
			<view class="paper-take" @click="openPaperPopup">
				取纸条
			</view>
		</view>
		
		<!-- 提示 -->
		<view class="tips">
			<view style="color: red;font-size: 40rpx;font-weight: 700;">提示：</view>
			<view class="" style="font-size: 30rpx;">
				当你不甘心等待的话，就主动出击吧！
			</view>
			<view class="" style="font-size: 30rpx;">
				正确填写信息，可以增加匹配几率哦！
			</view>
		</view>
	</view>
</template>

<script>
	import popup from '@/components/getPaper/popup.vue'
	export default {
		components:{
			popup
		},
		data() {
			return {
					swiperList:[
                    'https://cdn.uviewui.com/uview/swiper/swiper3.png',
                    'https://cdn.uviewui.com/uview/swiper/swiper2.png',
                    'https://cdn.uviewui.com/uview/swiper/swiper1.png',
                ],
				getPaperPopup:false,
			}
		},
		onShow() {
			this.getPaperPopup=false
		},
		onLoad() { 
	
		},
		methods: {
			savePaper(){
				uni.navigateTo({
				    url: '/pages/editPage/index'
				});
			},	
			openPaperPopup(){
				this.getPaperPopup=true
			},
			closePaperPopup(){
				this.getPaperPopup=false
			}
			
		},
		
	}
</script>

<style scoped lang="scss">
.paper{
	margin-top: 20rpx;
	width: 100vw;
	display: flex;
	justify-content: space-around;
	view{
		width: 45%;
		height: 450rpx;
		border: 1px solid red;
	}
}
.tips{
	margin-top:10rpx ;
	width:100%;
	padding: 20rpx;
		
	view{
	margin-bottom: 20rpx;
	}
}
</style>
